<template>
    <el-dialog
        v-model="dialogVisible"
        title="Tips"
        width="600"
        :before-close="handleClose"
    >
        
        <template #footer>
            <el-button @click="dialogVisible = false">Cancel</el-button>
            <el-button type="primary" @click="dialogVisible = false">
            Confirm
            </el-button>
        </template>
    </el-dialog>
</template>

<script lang="ts" setup>
import { ref } from 'vue'
const props = defineProps({
    visible:{
        type:Boolean,
        defualt:false
    }
})
const dialogVisible = ref(props.visible)
const emit = defineEmits(['undate:visible'])
const handleClose = (done: () => void) => {
    emit('undate:visible',false)
}
</script>
<style scoped>
.dialog-footer button:first-child {
  margin-right: 10px;
}
</style>